package com.xiaotu.common.utiles;

import lombok.AllArgsConstructor;
import lombok.Data;
import lombok.NoArgsConstructor;
import lombok.experimental.Accessors;
@Data
@AllArgsConstructor
@NoArgsConstructor
@Accessors(chain = true)
public class Result {
    private Integer code;
    private String msg;
    private Object obj;
    public static Result success(){
        return new Result(200, "成功", null);
    }
    public static Result success(Object obj){
        return new Result(200, "成功", obj);
    }
    public static Result error(){
        return new Result(500, "失败", null);
    }
}

